package com.yh.controller;

import com.yh.Iservice.BidService;
import com.yh.Iservice.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
@RequestMapping("log")
public class LoginController {

    @Autowired
    private BidService bidService;
    @Autowired
    private UserService userService;
    @RequestMapping("tologin")
    public String tologin(Model model){
        Integer i=bidService.tosize();
        Integer j=bidService.toseizew();
        //查询所有用户
        model.addAttribute("tos",i);
        model.addAttribute("tos",j);
        model.addAttribute("tou",userService.userList().size());
        model.addAttribute("tob",bidService.tosizeb());
        return "WEB-INF/view/bk_index";
    }
}
